/*******************************************************************************
* Project: QSAR(Cute Software Architecture) 
*
* Copyright: Copyright(C) 2024 by YuetingBen, All Rights Reserved
*
* File name: PduRCfg.h
*
* Brief: ;
*
* Author: Yueting.Ben
*
* Module: PDUR
*
* Generation Time: 2025-02-04 15:31:15
*
*******************************************************************************/

#ifndef PDURCFG_H
#define PDURCFG_H

/** HEADER FILES **/
#include "PduRType.h"
#include "PduRRte.h"


/** MACRO DEFINITION **/

/* PduHandleId */
#define PduRConf_PduHandleId_Com_Tx_Channel1_Qsar_Qsar_Can4  0u
#define PduRConf_PduHandleId_CanIf_Tx_Channel1_Qsar_Qsar_Can4  1u
#define PduRConf_PduHandleId_Com_Tx_Channel1_Qsar_Qsar_Can3  2u
#define PduRConf_PduHandleId_CanIf_Tx_Channel1_Qsar_Qsar_Can3  3u
#define PduRConf_PduHandleId_Dcm_Tx_Channel1_Qsar_DiagPhysResponse  4u
#define PduRConf_PduHandleId_CanTp_Tx_Channel1_Qsar_DiagPhysResponse  5u
#define PduRConf_PduHandleId_Com_Tx_Channel1_Qsar_Qsar_Can2  6u
#define PduRConf_PduHandleId_CanIf_Tx_Channel1_Qsar_Qsar_Can2  7u
#define PduRConf_PduHandleId_Com_Tx_Channel1_Qsar_Qsar_Can1  8u
#define PduRConf_PduHandleId_CanIf_Tx_Channel1_Qsar_Qsar_Can1  9u
#define PduRConf_PduHandleId_Com_Rx_Channel1_Other_Other_Can3  10u
#define PduRConf_PduHandleId_CanIf_Rx_Channel1_Other_Other_Can3  11u
#define PduRConf_PduHandleId_Dcm_Rx_Channel1_Tester_DiagFuncRequest  12u
#define PduRConf_PduHandleId_CanTp_Rx_Channel1_Tester_DiagFuncRequest  13u
#define PduRConf_PduHandleId_Dcm_Rx_Channel1_Tester_DiagPhysRequest  14u
#define PduRConf_PduHandleId_CanTp_Rx_Channel1_Tester_DiagPhysRequest  15u
#define PduRConf_PduHandleId_Com_Rx_Channel1_Other_Other_Can2  16u
#define PduRConf_PduHandleId_CanIf_Rx_Channel1_Other_Other_Can2  17u
#define PduRConf_PduHandleId_Com_Rx_Channel1_Other_Other_Can1  18u
#define PduRConf_PduHandleId_CanIf_Rx_Channel1_Other_Other_Can1  19u
#define PduRConf_PduHandleId_Max  20u

/* Routing path ID */
#define PduRConf_RoutingPath_Tx_Channel1_Qsar_Qsar_Can4  0u
#define PduRConf_RoutingPath_Tx_Channel1_Qsar_Qsar_Can3  1u
#define PduRConf_RoutingPath_Tx_Channel1_Qsar_DiagPhysResponse  2u
#define PduRConf_RoutingPath_Tx_Channel1_Qsar_Qsar_Can2  3u
#define PduRConf_RoutingPath_Tx_Channel1_Qsar_Qsar_Can1  4u
#define PduRConf_RoutingPath_Rx_Channel1_Other_Other_Can3  5u
#define PduRConf_RoutingPath_Rx_Channel1_Tester_DiagFuncRequest  6u
#define PduRConf_RoutingPath_Rx_Channel1_Tester_DiagPhysRequest  7u
#define PduRConf_RoutingPath_Rx_Channel1_Other_Other_Can2  8u
#define PduRConf_RoutingPath_Rx_Channel1_Other_Other_Can1  9u
#define PduRConf_RoutingPath_Max  10u

/** TYPEDEF DEFINITION **/

typedef struct
{
    CanTpTxIdType CanTpIndex;
}PduR_TxConfigType;


typedef struct
{
    CanTpTxIdType PduRIndex;
}PduR_RxConfigType;


typedef struct
{
    PduR_DestPduDataProvisionType pduDataProvision;
    PduIdType destPduHandleId;
    uint8 transmissionConfirmation;
    uint8 destPduRef; /* PduRDestPduRef */
}PduR_DestPduType;


typedef struct
{
    uint8 blockSize; /* PduRSourcePduBlockSize  */
    uint8 sourcePduHandleId; /* PduRSourcePduHandleId */
    uint8 srcPduUpTxConf; /* PduRSrcPduUpTxConf */
    uint8 srcPduRef; /* PduRSrcPduRef */
}PduR_SrcPduType;


typedef struct
{
    PduR_DestPduType* destPduPtr; /* PduRDestPduRRef */
    PduR_SrcPduType* srcPduPtr; /* PduRSrcPduRRef */
    uint8 queueDepth;/* PduRQueueDepth */
    uint16 tpThreshold;/* PduRTpThreshold */
    uint8* destBufferPtr; /* PduRDestBufferRef */
    PduR_RoutingModeType routingMode; /* RoutingMode */
}PduR_RoutingPathType;



/** LOCAL DATA DEFINITION **/
extern const PduR_RoutingPathType PduR_RoutingPath[PduRConf_RoutingPath_Max];
extern const PduR_ProviderFctIfType PduR_ProviderFctIf[PDUR_ROUTINGMODE_MAX];


#endif
